<?php if (!defined('THINK_PATH')) exit();?><!doctype html>
<html class="no-js fixed-layout">
<head>
    <meta charset="utf-8">
    <meta http-equiv="X-UA-Compatible" content="IE=edge">
    <title>Amaze UI Admin index Examples</title>
    <meta name="description" content="这是一个 index 页面">
    <meta name="keywords" content="index">
    <meta name="viewport" content="width=device-width, initial-scale=1">
    <meta name="renderer" content="webkit">
    <meta http-equiv="Cache-Control" content="no-siteapp"/>
    <link rel="icon" type="image/png" href="/Public/vendor/assets/i/favicon.png">
    <link rel="apple-touch-icon-precomposed" href="/Public/vendor/assets/i/app-icon72x72@2x.png">
    <meta name="apple-mobile-web-app-title" content="Amaze UI"/>
    <link rel="stylesheet" href="/Public/vendor/assets/css/amazeui.min.css"/>
    <link rel="stylesheet" href="/Public/vendor/assets/css/admin.css">
    
    <style>
        .daterangepicker {
            display: none;
        }
    </style>
    <!--<link rel="stylesheet" href="/Public/vendor/daterangepicker/daterangepicker.css">-->
    <link rel="stylesheet" href="/Public/vendor/datepicker/dist/datepicker.css" >


</head>
<body>
<!--[if lte IE 9]>
<p class="browsehappy">你正在使用<strong>过时</strong>的浏览器，Amaze UI 暂不支持。 请 <a href="http://browsehappy.com/" target="_blank">升级浏览器</a>
    以获得更好的体验！</p>
<![endif]-->

<header class="am-topbar am-topbar-inverse admin-header">
    <div class="am-topbar-brand">
        <strong>Amaze UI</strong> <small>后台管理模板</small>
    </div>

    <button class="am-topbar-btn am-topbar-toggle am-btn am-btn-sm am-btn-success am-show-sm-only" data-am-collapse="{target: '#topbar-collapse'}"><span class="am-sr-only">导航切换</span> <span class="am-icon-bars"></span></button>

    <div class="am-collapse am-topbar-collapse" id="topbar-collapse">

        <ul class="am-nav am-nav-pills am-topbar-nav am-topbar-right admin-header-list">
            <li><a href="javascript:;"><span class="am-icon-envelope-o"></span> 收件箱 <span class="am-badge am-badge-warning">5</span></a></li>
            <li class="am-dropdown" data-am-dropdown>
                <a class="am-dropdown-toggle" data-am-dropdown-toggle href="javascript:;">
                    <span class="am-icon-users"></span>欢迎<?php echo ($_SESSION[user]['username']); ?> 管理员 <span class="am-icon-caret-down"></span>
                </a>
                <ul class="am-dropdown-content">
                    <li><a href="#"><span class="am-icon-user"></span> 资料</a></li>
                    <li><a href="#"><span class="am-icon-cog"></span> 设置</a></li>
                    <li><a href="<?php echo U('User/logout');?>"><span class="am-icon-power-off"></span> 退出</a></li>
                </ul>
            </li>
            <li class="am-hide-sm-only"><a href="javascript:;" id="admin-fullscreen"><span class="am-icon-arrows-alt"></span> <span class="admin-fullText">开启全屏</span></a></li>
        </ul>
    </div>
</header>

    <div class="am-cf admin-main">
        <!-- sidebar start -->
        <div class="admin-sidebar am-offcanvas" id="admin-offcanvas">
    <div class="am-offcanvas-bar admin-offcanvas-bar">
        <ul class="am-list admin-sidebar-list">
            <li><a href="<?php echo U('Index/index');?>"><span class="am-icon-home"></span> 首页</a></li>
            <li class="admin-parent">
                <a class="am-cf" data-am-collapse="{target: '#collapse-nav'}"><span class="am-icon-shopping-cart"></span> 商城中心 <span class="am-icon-angle-right am-fr am-margin-right"></span></a>
                <ul class="am-list am-collapse admin-sidebar-sub am-in" id="collapse-nav">
                    <li><a href="<?php echo U('Product/index');?>" class="am-cf"><span class="am-icon-product-hunt"></span> 商品管理<span class="am-badge am-badge-secondary am-margin-right am-fr">33</span></a></li>
                    <li><a href="<?php echo U('Category/index');?>"><span class="am-icon-puzzle-piece"></span> 分类管理</a></li>
                    <li><a href="scription:;"><span class="am-icon-th"></span> 相册页面<span class="am-badge am-badge-secondary am-margin-right am-fr">24</span></a></li>
                    <li><a href="<?php echo U('Advert/index');?>"><span class="am-icon-calendar"></span> 广告管理</a></li>
                    <li><a href="<?php echo U('Customer/index');?>"><span class="am-icon-user"></span> 会员管理</a></li>
                    <li><a href="<?php echo U('Order/index');?>"><span class="am-icon-first-order"></span> 订单管理</a></li>
                    <li><a href="<?php echo U('Product/recycle');?>"><span class="am-badge am-badge-danger am-margin-right am-fr">22</span> 商品回收站</a></li>
                </ul>
            </li>
            <li class="admin-parent">
                <a class="am-cf" data-am-collapse="{target: '#collapse-abc'}"><span class="am-icon-shopping-cart"></span> 系统管理 <span class="am-icon-angle-right am-fr am-margin-right"></span></a>
                <ul class="am-list am-collapse admin-sidebar-sub am-in" id="collapse-abc">
                    <li><a href="<?php echo U('AuthSet/rule_manage');?>" class="am-cf"><span class="am-icon-product-hunt"></span> 菜单与权限<span class="am-badge am-badge-secondary am-margin-right am-fr">33</span></a></li>
                    <li><a href="<?php echo U('AuthSet/group_manage');?>"><span class="am-icon-puzzle-piece"></span> 用户组管理</a></li>
                    <li><a href="<?php echo U('AuthSet/user_manage');?>"><span class="am-icon-calendar"></span> 用户管理</a></li>
                </ul>
            </li>
            <li><a href="admin-table.html"><span class="am-icon-table"></span> 表格</a></li>
            <li><a href="admin-form.html"><span class="am-icon-pencil-square-o"></span> 表单</a></li>
            <li><a href="#"><span class="am-icon-sign-out"></span> 注销</a></li>
        </ul>

        <div class="am-panel am-panel-default admin-sidebar-panel">
            <div class="am-panel-bd">
                <p><span class="am-icon-bookmark"></span> 公告</p>
                <p>时光静好，与君语；细水流年，与君同。—— Amaze UI</p>
            </div>
        </div>

        <div class="am-panel am-panel-default admin-sidebar-panel">
            <div class="am-panel-bd">
                <p><span class="am-icon-tag"></span> wiki</p>
                <p>Welcome to the Amaze UI wiki!</p>
            </div>
        </div>
    </div>
</div>


            <!-- sidebar end -->

            <!-- content start -->
            


    <!-- content start -->
    <div class="admin-content">
        <div class="admin-content-body">
            <div class="am-cf am-padding am-padding-bottom-0">
                <div class="am-fl am-cf"><strong class="am-text-primary am-text-lg">会员列表</strong> /
                    <small>Customer List</small>
                </div>
            </div>

            <hr>


            <div class="am-g">

                <form class="am-form-inline" role="form" method="get">

                    <div class="am-form-group">
                        <input style="width: 130px;height: 32px;margin: 2px 2px" type="text" class="am-form-field"
                               name="nickname"
                               placeholder="按昵称" value="<?php echo ($_GET['nickname']); ?>">

                    </div>

                    <div class="am-form-group">
                        <input style="width: 130px;height: 32px;margin: 2px 2px" type="text" class="am-form-field"
                               name="mobile"
                               placeholder="按手机号" value="<?php echo ($_GET['mobile']); ?>">

                    </div>


                    <div class="am-form-group">
                        <div class="am-input-group am-input-group-sm">
                            <input type="text" data-toggle="datepicker" name="birthday" class="am-form-field" style="width: 180px">
                            <span class="am-input-group-btn">
                            <button class="am-btn am-btn-default" type="submit">搜索</button>
                            </span>
                            <span class="am-input-group-btn">
                            <a href="<?php echo U('Customer/index');?>" class="am-btn am-btn-default" type="button">重置</a>
                            </span>
                        </div>
                    </div>
                </form>
            </div>

            <div class="am-g">
                <div class="am-u-sm-12">
                    <form class="am-form">
                        <table class="am-table am-table-striped am-table-hover table-main">
                            <thead>
                            <tr>
                                <th class="table-check"><input type="checkbox"/></th>
                                <th class="table-id">ID</th>
                                <th class="table-title">昵称</th>
                                <th class="table-title">头像</th>
                                <th class="table-type">性别</th>
                                <th class="table-type">手机号</th>
                                <th class="table-author am-hide-sm-only">生日</th>
                                <th class="table-author am-hide-sm-only">邮箱</th>
                                <th class="table-date am-hide-sm-only">注册时间</th>
                                <th class="table-set">操作</th>
                            </tr>
                            </thead>
                            <tbody>
                            <?php if(is_array($customers)): $i = 0; $__LIST__ = $customers;if( count($__LIST__)==0 ) : echo "" ;else: foreach($__LIST__ as $key=>$customer): $mod = ($i % 2 );++$i;?><tr>
                                <td><input type="checkbox"/></td>
                                <td><?php echo ($customer["id"]); ?></td>
                                <td class="am-hide-sm-only"><?php echo ($customer["nickname"]); ?></td>
                                <td><a href="#">
                                    <img src="<?php echo ($customer["thumb"]); ?>" alt="" style="width: 60px;height: 60px">

                                </a></td>
                                <td>
                                    <?php if(($customer["sex"]) == "1"): ?><span class="am-icon-btn am-primary am-icon-male"></span>
                                        <?php else: ?>
                                        <span class="am-icon-btn am-danger am-icon-female"></span><?php endif; ?>
                                </td>
                                <td class="am-hide-sm-only"><?php echo ($customer["mobile"]); ?></td>
                                <td class="am-hide-sm-only"><?php echo (date("Y-m-d",$customer["birthday"])); ?></td>
                                <td class="am-hide-sm-only"><?php echo ($customer["email"]); ?></td>
                                <td class="am-hide-sm-only"><?php echo (date("Y-m-d",$customer["created_at"])); ?></td>
                                <td>
                                    <div class="am-btn-toolbar">
                                        <div class="am-btn-group am-btn-group-xs">
                                            <a href="<?php echo U('Order/index',['name'=>$customer[nickname]]);?>"
                                               class="am-btn am-btn-secondary am-btn-xs"><span
                                                    class="am-icon-eye"></span> 查看订单
                                            </a>
                                        </div>
                                    </div>
                                </td>
                            </tr><?php endforeach; endif; else: echo "" ;endif; ?>
                            </tbody>
                        </table>
                        <div class="am-cf">
                            共 <?php echo ($count); ?> 条记录
                            <div class="am-fr">
                                <ul class="am-pagination">
                                    <li class="am-disabled"><a href="#">«</a></li>
                                    <li class="am-active"><a href="#">1</a></li>
                                    <?php echo ($pages); ?>
                                    <li><a href="#">»</a></li>
                                </ul>
                            </div>
                        </div>
                        <hr/>
                        <p>注：.....</p>
                    </form>
                </div>

            </div>
        </div>

        <footer class="admin-content-footer">
            <hr>
            <p class="am-padding-left">© 2014 AllMobilize, Inc. Licensed under MIT license.</p>
        </footer>

    </div>
    <!-- content end -->

            <!-- content end -->

    </div>

    <a href="#" class="am-icon-btn am-icon-th-list am-show-sm-only admin-menu"
       data-am-offcanvas="{target: '#admin-offcanvas'}"></a>

    <!--[if lt IE 9]>
    <script src="http://libs.baidu.com/jquery/1.11.1/jquery.min.js"></script>
    <script src="http://cdn.staticfile.org/modernizr/2.8.3/modernizr.js"></script>
    <script src="/Public/vendor/assets/js/amazeui.ie8polyfill.min.js"></script>
    <![endif]-->

    <!--[if (gte IE 9)|!(IE)]><!-->
    <script src="/Public/vendor/assets/js/jquery.min.js"></script>
    <!--<![endif]-->
    <script src="/Public/vendor/assets/js/amazeui.min.js"></script>
    <script src="/Public/vendor/assets/js/app.js"></script>
    
    <!--<script src="/Public/vendor/daterangepicker/moment.js"></script>-->
    <script src="/Public/vendor/moment/locale/zh-cn.js"></script>
    <!--<script src="/Public/vendor/daterangepicker/daterangepicker.js"></script>-->
    <!--<script src="/Public/assets/admin/js/daterange_config.js"></script>-->
    <script src="/Public/vendor/datepicker/dist/datepicker.js"></script>
    <script src="/Public/vendor/datepicker/i18n/datepicker.zh-CN.js"></script>

    <script>
        $(function () {
            $('[data-toggle="datepicker"]').datepicker({
                language: 'zh-CN'
            });
        })
    </script>


</body>
</html>